/**
 * Copyright 2009 by Christian Scheid. This file is part of the switch eclipse plugin and is licensed under the
 * GPL version 3. Please refer to the URL http://www.gnu.org/licenses/gpl-3.0.html for details.
 */
package org.digitalsoul.switchplugin;

import org.digitalsoul.switchplugin.model.SwitchFile;

import org.eclipse.core.resources.IFile;


public class MockSwitchFile extends SwitchFile {

    private Boolean exists;
    
    public MockSwitchFile(IFile file) {
        super(file);
        this.file = file;
    }

    public void setExists(boolean existingAction) {
        exists = false;
    }
    
    @Override
    public boolean exists() {
        if (exists == null) {
            return super.exists();
        }
        return exists;
    }
}
